package com.gf.gf_data.controller;

import com.gf.gf_data.dto.BaseResult;
import com.gf.gf_data.sys.annotation.Access;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/test")
public class TestController {

    private static Logger log = LoggerFactory.getLogger(TestController.class);

    @Access(authorities = {"admin"})
    @GetMapping(value = "/hh", produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
    public BaseResult testAA(){
        log.info("invoke-------------/test/hh.get");
        return new BaseResult<>(true,  "Successful");
    }

}
